/**
 * SKZR.ORG JS Library 0.1
 * Copyright(c) 2009-2014, SKZR.ORG JS, LLC.
 * @author skzr.org(E-mail:skzr.org@gmail.com)
 */

/**
 * 数据管理系统
 */
Skzr.book = {version: '0.0.1'};


var test11 = function () {
	var root = new Ext.tree.TreeNode();
	var node1 = new Ext.tree.TreeNode({
		text:'书籍类型维护',
		url:'http://www.baidu.com.cn'
	});
	var node2 = new Ext.tree.TreeNode({
		text:'书籍维护',
		url:'http://www.google.cn'
	});
	root.appendChild(node1);
	root.appendChild(node2);
	var menu = new Ext.tree.TreePanel({
		border:false,
		root:root,
		rootVisible:false,//不显示根节点
		listeners:{
			click:function(node, e) {
				mainPanel.load({
					url:node.attributes.url,
					callback:function() {
						mainPanel.setTitle(node.text);
					}
				});
			}
		}
	});
	
	Skzr.book.viewport = new Ext.Viewport({
		layout:'border',
		items:[
			{
				title:'简易书籍管理系统ExtJS版',
				collapsible:true,
				html:'简易书籍管理系统',
				region:'north',
				height:100
			},{
				title:'功能菜单',
				split:true,
				collapsible:true,
				region:'west',
				width:150,
				items:menu
			},{
				title:'系统说明',
				collapsible:true,
				region:'center',
				html:'系统说明哦',
				id:'mainContent'
			}
		]
	});
	
	var mainPanel = Ext.getCmp('mainContent');
}